{	Problem: http://codeforces.ru/problemset/problem/11/A
	Verdict: Accepted

}
var n,i,d,cur,t:longint; a:array[1..2001] of int64;
begin
readln(n,d);
for i:=1 to n do read(a[i]);
cur:=0;
for i:=2 to n do begin
  if a[i]<=a[i-1] then begin
    t:=abs(a[i]-a[i-1]);
    inc(cur,t div d+1);
    inc(a[i],(t div d+1)*d);
  end;
end;
writeln(cur);
end.